package lbframework.classe;

import java.net.Authenticator;

public class Proxy {

    public static String ip = "";
    public static String porta = "";
    public static String usuario = "";
    public static String senha = "";

    public static void setProxy() {
        System.setProperty("http.proxySet", "true");
        System.setProperty("http.proxyHost", ip);
        System.setProperty("http.proxyPort", porta);

        System.setProperty("https.proxySet", "true");
        System.setProperty("https.proxyHost", ip);
        System.setProperty("https.proxyPort", porta);

        Authenticator.setDefault(new SimpleAuthenticator(usuario, senha));
    }
}
